<?php
require('init.php');


if( isset( $_POST['able']) OR isset( $_POST['disable']) ){

if( isset( $_POST['able']) )
{

	$teams = explode(",", $_POST['teams']);
	
	for( $i=0; $i<count($teams); $i++)
	{
		enable_team($teams[$i], $conn_db1, '1');
	}
}

if( isset( $_POST['disable']) )
{
	$teams = explode(",", $_POST['teams']);
	
	for( $i=0; $i<count($teams); $i++)
	{
		enable_team($teams[$i], $conn_db1, '0');
	}
}
	header('Location:teams.php');
}else{
	header('Location:index.php');
}

?>
